package com.winit.openapi.claim.builder;

import java.util.HashMap;
import java.util.Map;

import org.springframework.stereotype.Service;

import com.alibaba.fastjson.JSONObject;

@Service("tailTraceOrderBuilder")
public class TailTraceOrderBuilder {

    public Map<String, Object> buildTailTraceOrderCreate(JSONObject input) {
        Map<String, Object> data = new HashMap<String, Object>();
        if (input.containsKey("submitterAcc")) {
            data.put("submitterAcc", input.get("submitterAcc"));

        }
        if (input.containsKey("isTom")) {
            data.put("isTom", input.get("isTom"));

        }
        if (input.containsKey("queryType")) {
            data.put("queryType", input.get("queryType"));

        }
        if (input.containsKey("orderNo")) {
            data.put("orderNo", input.get("orderNo"));

        }
        if (input.containsKey("checkingType")) {
            data.put("checkingType", input.get("checkingType"));

        }
        if (input.containsKey("queryType")) {
            data.put("queryType", input.get("queryType"));

        }
        if (input.containsKey("noteMsg")) {
            data.put("noteMsg", input.get("noteMsg"));

        }
        if (input.containsKey("emails")) {
            data.put("emails", input.get("emails"));

        }
        if (input.containsKey("ctx")) {
            data.put("ctx", input.get("ctx"));

        }
        return data;
    }

    public Map<String, Object> buildGetOrderList(JSONObject input) {
        Map<String, Object> data = new HashMap<String, Object>();
        if (input.containsKey("ids")) {
            data.put("ids", input.get("ids"));

        }
        if (input.containsKey("ctx")) {
            data.put("ctx", input.get("ctx"));

        }
        return data;
    }

}
